import http from "../assets/js/http";
//
/**
 *  @parms resquest 请求地址 例如：http://197.82.15.15:8088/request/...
 *  @param '/testIp'代表vue-cil中config，index.js中配置的代理
 */
let resquest = "http://apitest.zlinkiot.com:12100/"; //测试
let wsUrl = "ws://apitest.zlinkiot.com:12100/websocket/ws/connect";
let unoUrl = "http://106.60.12.111:1662" // 优诺地址

// let resquest = "https://zhydapi.zlink.group/"; //正式
// let wsUrl = "wss://zhydapi.zlink.group/websocket/ws/connect";
// let unoUrl = "https://106.60.12.111:1662"//优诺地址

// get请求
export default {
  getListAPI(api, params) {
    return http.get(`${resquest}` + api, params);
  },
  postFormAPI(api, params, type) {
    return http.post(`${resquest}` + api, params, type);
  },
  getUrl() {
    return resquest;
  },
  getWsUrl() {
    return wsUrl;
  },
  getUnoUrl() {
    return unoUrl;
  },
};
